package edu.sjb_beta1.characters;

import javax.swing.JLabel;

public abstract class Character extends JLabel {
    private String name;

    public String getName() {
        return name;
    }

    public void setName(String n) {
        name = n;
    }

    public double getPositionX() {
        return this.getLocation().getX();
    }

    public void setPositionX(double posX) {
        setLocation((int) posX, (int) getPositionY());
    }

    public double getPositionY() {
        return getLocation().getY();
    }

    public void setPositionY(double posY) {
        setLocation((int) getPositionX(), (int) posY);
    }

    public abstract void move(double x, double y);
}
